package com.bocai.service.impl;

import com.bocai.bean.SysTabManager;
import com.bocai.bean.TAdInfo;
import com.bocai.mapper.SysTabManagerMapper;
import com.bocai.mapper.TAdInfoMapper;
import com.bocai.service.IAdInfoService;
import com.bocai.service.ITabService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class TabServiceImpl implements ITabService {

    @Autowired
    private SysTabManagerMapper sysTabManagerMapper;

    @Override
    public List<SysTabManager> selectTab(SysTabManager sysTab) {
        return sysTabManagerMapper.selectTabList(sysTab);
    }

    @Override
    public List<SysTabManager> selectTabs(String tabIds) {
        return sysTabManagerMapper.selectTabLists(tabIds);
    }

    @Override
    public int insertTab(SysTabManager sysTab) {
        return sysTabManagerMapper.insert(sysTab);
    }

    @Override
    public int updateTab(SysTabManager sysTab) {
        return sysTabManagerMapper.updateByPrimaryKeySelective(sysTab);
    }

    @Override
    public int deleteTab(int tabId) {
        return sysTabManagerMapper.deleteByPrimaryKey(tabId);
    }
}
